import {
    CHANGE_INPUT_VALUE,
    ADD_TODO_ITEM,
    DELETE_TODO_ITEM
} from "./actionTypes";

//如果异步函数返回的是一个对象，就用小括号包裹着花括号
export const getInputChangeAction = (value) => ({
    type: CHANGE_INPUT_VALUE,
    value
})

export const getAddItemAction = () => ({
    type: ADD_TODO_ITEM
})

export const getDeleteItemAction = (value) => ({
    type: DELETE_TODO_ITEM,
    value
})